import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import * as echarts from 'echarts'
import ElementUI from 'element-ui'
import GlobalComponent from './components/index'
import Api from './api/index.js'
import * as Columns from './assets/js/columns.js'
import Directive from '@/directive/index.js' // 自定义指令
// import letOut from "./utils/letOut";
import quinn from './utils/quinn'
import 'element-ui/lib/theme-chalk/index.css'
import './assets/css/index.less'
import { $acc, API_HOST, IMG_HOST } from '@/assets/js/define.js'
import '@/store/preventReClick'
import dataV from '@jiaminghi/data-view'

Vue.use(dataV)
// Vue.use(letOut, {timeout: 10 * 60 * 1000, router})
Vue.use(Api)
Vue.use(Directive)
Vue.use(ElementUI)
Vue.use(GlobalComponent)
Vue.prototype.$echarts = echarts
Vue.prototype.$columns = Columns
Vue.prototype.$quinn = quinn
Vue.prototype.$acc = $acc
Vue.prototype.$apiHost = API_HOST
Vue.prototype.$imgHost = IMG_HOST
window.$quinn = Vue.prototype.$quinn
// new Vue({
//     router,
//     render: h => h(App),
//     mounted() {
//         // 启动检测
//         this.$idleLogout.start()
//     }
// }).$mount("#app")
window.vue = new Vue({
  router,
  store,
  render: (h) => h(App),
}).$mount('#app')
Vue.directive('removeAriaHidden', {
  bind(el, binding) {
    let ariaEls = el.querySelectorAll('.el-radio__original')
    ariaEls.forEach((item) => {
      item.removeAttribute('aria-hidden')
    })
  },
})

//关闭
// this.$idleLogout.stop()
